﻿using System;

// Token: 0x020002DE RID: 734
public class CharMaleFile : global::CharFile
{
	// Token: 0x060011EB RID: 4587 RVA: 0x00091DC0 File Offset: 0x0008FFC0
	public CharMaleFile() : base("【HoneySelectCharaMale】", "chara/male/")
	{
		global::CharFileInfoCustomMale charFileInfoCustomMale = new global::CharFileInfoCustomMale();
		this.maleCustomInfo = charFileInfoCustomMale;
		base.customInfo = charFileInfoCustomMale;
		global::CharFileInfoClothesMale charFileInfoClothesMale = new global::CharFileInfoClothesMale();
		this.maleClothesInfo = charFileInfoClothesMale;
		base.clothesInfo = charFileInfoClothesMale;
		global::CharFileInfoCoordinateMale charFileInfoCoordinateMale = new global::CharFileInfoCoordinateMale();
		this.maleCoordinateInfo = charFileInfoCoordinateMale;
		base.coordinateInfo = charFileInfoCoordinateMale;
		global::CharFileInfoStatusMale charFileInfoStatusMale = new global::CharFileInfoStatusMale();
		this.maleStatusInfo = charFileInfoStatusMale;
		base.statusInfo = charFileInfoStatusMale;
		global::CharFileInfoParameterMale charFileInfoParameterMale = new global::CharFileInfoParameterMale();
		this.maleParameterInfo = charFileInfoParameterMale;
		base.parameterInfo = charFileInfoParameterMale;
	}

	// Token: 0x1700027A RID: 634
	// (get) Token: 0x060011EC RID: 4588 RVA: 0x00091E44 File Offset: 0x00090044
	// (set) Token: 0x060011ED RID: 4589 RVA: 0x00091E4C File Offset: 0x0009004C
	public global::CharFileInfoCustomMale maleCustomInfo { get; set; }

	// Token: 0x1700027B RID: 635
	// (get) Token: 0x060011EE RID: 4590 RVA: 0x00091E58 File Offset: 0x00090058
	// (set) Token: 0x060011EF RID: 4591 RVA: 0x00091E60 File Offset: 0x00090060
	public global::CharFileInfoClothesMale maleClothesInfo { get; set; }

	// Token: 0x1700027C RID: 636
	// (get) Token: 0x060011F0 RID: 4592 RVA: 0x00091E6C File Offset: 0x0009006C
	// (set) Token: 0x060011F1 RID: 4593 RVA: 0x00091E74 File Offset: 0x00090074
	public global::CharFileInfoCoordinateMale maleCoordinateInfo { get; set; }

	// Token: 0x1700027D RID: 637
	// (get) Token: 0x060011F2 RID: 4594 RVA: 0x00091E80 File Offset: 0x00090080
	// (set) Token: 0x060011F3 RID: 4595 RVA: 0x00091E88 File Offset: 0x00090088
	public global::CharFileInfoStatusMale maleStatusInfo { get; set; }

	// Token: 0x1700027E RID: 638
	// (get) Token: 0x060011F4 RID: 4596 RVA: 0x00091E94 File Offset: 0x00090094
	// (set) Token: 0x060011F5 RID: 4597 RVA: 0x00091E9C File Offset: 0x0009009C
	public global::CharFileInfoParameterMale maleParameterInfo { get; set; }

	// Token: 0x060011F6 RID: 4598 RVA: 0x00091EA8 File Offset: 0x000900A8
	public override bool LoadFromSBPR(string path)
	{
		global::CharSave_SexyBeachPR charSave_SexyBeachPR = new global::CharSave_SexyBeachPR(global::CharSave_SexyBeachPR.ConvertType.HoneySelect);
		if (!charSave_SexyBeachPR.LoadCharaFile(path))
		{
			return false;
		}
		global::CharSave_SexyBeachPR.SaveData savedata = charSave_SexyBeachPR.savedata;
		if (savedata.sex == 1)
		{
			global::Debug.LogWarning("キャラファイルの性別が違います");
			return false;
		}
		this.charaFileName = savedata.fileName;
		this.charaFilePNG = savedata.pngData;
		this.maleCustomInfo.personality = savedata.personality;
		this.maleCustomInfo.name = savedata.name;
		this.maleCustomInfo.headId = savedata.headId;
		for (int i = 0; i < savedata.shapeBody.Length; i++)
		{
			this.maleCustomInfo.shapeValueBody[i] = global::CharFile.ClampEx(savedata.shapeBody[i], 0f, 1f);
		}
		for (int j = 0; j < savedata.shapeFace.Length; j++)
		{
			this.maleCustomInfo.shapeValueFace[j] = global::CharFile.ClampEx(savedata.shapeFace[j], 0f, 1f);
		}
		for (int k = 0; k < this.maleCustomInfo.hairId.Length; k++)
		{
			this.maleCustomInfo.hairId[k] = savedata.hairId[k];
			savedata.hairColor[k].CopyToHoneySelect(this.maleCustomInfo.hairColor[k]);
			savedata.hairAcsColor[k].CopyToHoneySelect(this.maleCustomInfo.hairAcsColor[k]);
		}
		this.maleCustomInfo.texFaceId = savedata.texFaceId;
		this.maleCustomInfo.matBeardId = savedata.beardId;
		savedata.beardColor.CopyToHoneySelect(this.maleCustomInfo.beardColor);
		savedata.skinColor.CopyToHoneySelect(this.maleCustomInfo.skinColor);
		this.maleCustomInfo.texTattoo_fId = savedata.texTattoo_fId;
		savedata.tattoo_fColor.CopyToHoneySelect(this.maleCustomInfo.tattoo_fColor);
		this.maleCustomInfo.matEyebrowId = savedata.matEyebrowId;
		savedata.eyebrowColor.CopyToHoneySelect(this.maleCustomInfo.eyebrowColor);
		this.maleCustomInfo.matEyeLId = savedata.matEyeLId;
		savedata.eyeLColor.CopyToHoneySelect(this.maleCustomInfo.eyeLColor);
		this.maleCustomInfo.matEyeRId = savedata.matEyeRId;
		savedata.eyeRColor.CopyToHoneySelect(this.maleCustomInfo.eyeRColor);
		savedata.eyeWColor.CopyToHoneySelect(this.maleCustomInfo.eyeWColor);
		this.maleCustomInfo.texFaceDetailId = 1;
		this.maleCustomInfo.faceDetailWeight = savedata.faceDetailWeight;
		this.maleCustomInfo.texBodyId = savedata.texBodyId;
		this.maleCustomInfo.texTattoo_bId = savedata.texTattoo_bId;
		savedata.tattoo_bColor.CopyToHoneySelect(this.maleCustomInfo.tattoo_bColor);
		this.maleCustomInfo.texBodyDetailId = savedata.texBodyId + 1;
		this.maleCustomInfo.bodyDetailWeight = savedata.bodyDetailWeight;
		global::CharFileInfoClothesMale charFileInfoClothesMale = new global::CharFileInfoClothesMale();
		charFileInfoClothesMale.clothesId[0] = savedata.coord[0].clothesTopId;
		savedata.coord[0].clothesTopColor.CopyToHoneySelect(charFileInfoClothesMale.clothesColor[0]);
		charFileInfoClothesMale.clothesId[1] = savedata.coord[0].shoesId;
		savedata.coord[0].shoesColor.CopyToHoneySelect(charFileInfoClothesMale.clothesColor[1]);
		for (int l = 0; l < 5; l++)
		{
			charFileInfoClothesMale.accessory[l].type = savedata.accessory[0, l].accessoryType;
			charFileInfoClothesMale.accessory[l].id = savedata.accessory[0, l].accessoryId;
			charFileInfoClothesMale.accessory[l].parentKey = savedata.accessory[0, l].parentKey;
			charFileInfoClothesMale.accessory[l].addPos = savedata.accessory[0, l].plusPos;
			charFileInfoClothesMale.accessory[l].addRot = savedata.accessory[0, l].plusRot;
			charFileInfoClothesMale.accessory[l].addScl = savedata.accessory[0, l].plusScl;
			savedata.accessoryColor[0, l].CopyToHoneySelect(charFileInfoClothesMale.accessory[l].color);
		}
		this.maleCoordinateInfo.SetInfo(global::CharDefine.CoordinateType.type00, charFileInfoClothesMale);
		global::CharFileInfoClothesMale charFileInfoClothesMale2 = new global::CharFileInfoClothesMale();
		charFileInfoClothesMale2.clothesId[0] = savedata.coord[1].clothesTopId;
		savedata.coord[1].clothesTopColor.CopyToHoneySelect(charFileInfoClothesMale2.clothesColor[0]);
		charFileInfoClothesMale2.clothesId[1] = savedata.coord[1].shoesId;
		savedata.coord[1].shoesColor.CopyToHoneySelect(charFileInfoClothesMale2.clothesColor[1]);
		for (int m = 0; m < 5; m++)
		{
			charFileInfoClothesMale2.accessory[m].type = savedata.accessory[1, m].accessoryType;
			charFileInfoClothesMale2.accessory[m].id = savedata.accessory[1, m].accessoryId;
			charFileInfoClothesMale2.accessory[m].parentKey = savedata.accessory[1, m].parentKey;
			charFileInfoClothesMale2.accessory[m].addPos = savedata.accessory[1, m].plusPos;
			charFileInfoClothesMale2.accessory[m].addRot = savedata.accessory[1, m].plusRot;
			charFileInfoClothesMale2.accessory[m].addScl = savedata.accessory[1, m].plusScl;
			savedata.accessoryColor[1, m].CopyToHoneySelect(charFileInfoClothesMale2.accessory[m].color);
		}
		this.maleCoordinateInfo.SetInfo(global::CharDefine.CoordinateType.type02, charFileInfoClothesMale2);
		base.ChangeCoordinateType(global::CharDefine.CoordinateType.type00);
		return true;
	}
}
